

import json

def say(name):
    print('hello',name)

info = {
    'name':'ouyang',
    'age':22,
    # 'func':say  #内存地址
}
f = open('a.txt', 'w')
f.write(json.dumps(info) )

info['age']= 230

f.write(json.dumps(info) )
f.close()
